package chapter8;

/**
 * @author lzy
 * @version v1.0
 * Create DateTime: 2019/3/8 15:37
 */
public class ReferenceCounting {
    public static void main(String[] args) {
        Shared shared = new Shared();
        Composing[] composings = {new Composing(shared), new Composing(shared), new Composing(shared), new Composing(shared)};
        for (Composing composing : composings) {
            composing.dispose();
        }
    }
}
